package com.lkj.project.dtqh.controller;

import com.lkj.framework.annotation.GetMapping;
import com.lkj.framework.annotation.RequestMapping;
import com.lkj.framework.annotation.RestController;
import com.lkj.project.dtqh.domain.DtCpgz;
import com.lkj.project.dtqh.service.DtCpgzService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;

import javax.annotation.Resource;

/**
 * 出票规则(DtCpgz)表控制层
 *
 * @author likj
 * @since 2021-01-22 16:16:14
 */
//@RestController
@RequestMapping("dtCpgz")
@Slf4j
@Controller
public class DtCpgzController {
    /**
     * 服务对象
     */
    @Autowired
    private DtCpgzService dtCpgzService;

    /**
     * 通过主键查询单条数据
     *
     * @param id 主键
     * @return 单条数据
     */
    @GetMapping("selectOne")
    public String selectOne(String params) {

        log.info(params);


        Integer cpgzDm = 1;
        DtCpgz dtCpgz = dtCpgzService.queryById(cpgzDm);
        System.out.println(dtCpgz);
        return "This is my controller";
    }

}